using System;
using System.Collections.Generic;
using System.Text;
using System.Configuration;

namespace Axe.Web.Security.Membership
{
    public class PasswordResetConfiguration : ConfigurationElement
    {
        [ConfigurationProperty("providerType", DefaultValue = "Axe.Web.Security.Membership.SQL.SqlPasswordResetRequestManager, TTG.Engine")]
        public string ProviderType
        {
            get { return (string)base["providerType"]; }
        }

        [ConfigurationProperty("requestExpirationTime", IsRequired=true)]
        public int RequestExpirationTimeInMinutes
        {
            get
            {
                return (int)base["requestExpirationTime"];
            }
        }

        public TimeSpan RequestExpirationTime
        {
            get
            {
                return TimeSpan.FromMinutes(RequestExpirationTimeInMinutes);
            }
        }

        [ConfigurationProperty("fromAdress", IsRequired = true)]
        public string FromAdress
        {
            get { return (string)base["fromAdress"]; }
            set { base["fromAdress"] = value; }
        }
    }
}
